import request from '@/utils/request'

// 个人中心信息
export function getPersonalInfo() {
	return request({
		headers: {
			"isToken": true
		},
		url: "/h5/companion/staff/getStaffInfo",
		method: 'get'
	})
}

//获取openId
export function getOpenId(code) {
	return request({
		url: `/no-auth/wechat/getOpenId?code=${code}&sourceType=1`,
		method: 'get'
	})
}

//获取手机号
export function getPhoneNumber(data) {
	return request({
		url: `/applet/login/bindPhone`,
		method: 'post',
		data
	})
}

// 微信授权登录
export const wxLogin = (data) => {
	return request({
		url: `/applet/login/wechatLogin`,
		method: 'post',
		data
	})
}